package net.web.belerofont.action.validation;

import java.util.regex.Pattern;

public class ValidationPerform {
	
	public boolean perform(String expression, String value) {
		
		if (value == null || value.trim().equals(""))
			return false;
		
		Pattern p;
		java.util.regex.Matcher m;
		
		p = Pattern.compile(expression,  Pattern.CASE_INSENSITIVE);
		m = p.matcher(value);

		return m.matches();
	}

}
